package com.tfd.blog.utlis;

import java.text.DateFormat;
import java.text.SimpleDateFormat;
import java.util.Date;

/**
 * @author TangFD@HF 2019/5/22.
 */
public class DateUtils {
    private static final DateFormat timeFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm");

    public static String timeFormat(Date date) {
        if (date == null) {
            return "";
        }

        return timeFormat.format(date);
    }
}
